# 使用 cmd.exe 替代 sh: https://just.systems/man/zh/%E9%A2%84%E5%A4%87%E7%9F%A5%E8%AF%86.html#:~:text=%E5%9C%A8%20Windows%20%E4%B8%8A%EF%BC%8C%20just%20%E5%8F%AF%E4%BB%A5%E4%BD%BF%E7%94%A8%20Git%20for%20Windows,Write-Host%20%22Hello%2C%20world%21%22%20%E2%80%A6%E6%88%96%E8%80%85%20cmd.exe%3A%20dir%20%E4%BD%A0%E4%B9%9F%E5%8F%AF%E4%BB%A5%E4%BD%BF%E7%94%A8%E5%91%BD%E4%BB%A4%E8%A1%8C%E5%8F%82%E6%95%B0%E6%9D%A5%E8%AE%BE%E7%BD%AE%20Shell%E3%80%82
set shell := ["cmd.exe", "/c"]

build-windows:
  go mod tidy
  SET CGO_ENABLED=0
  go build -v -o tuiftp.exe .

run:
    go mod tidy
    go run .

gc:
  git add .
  git commit

clean:
    del *.exe


gcl:
  -git clone https://ghproxy.cn/https://github.com/charmbracelet/bubbletea 3rd/bubbletea
  -git clone https://ghproxy.cn/https://github.com/charmbracelet/bubbles 3rd/bubbles
  -git clone https://ghproxy.cn/https://github.com/go-task/task 3rd/task
  @echo "if ghproxy.cn is not work, change to .net | .org | .cc"

list-dir:
  dir

goreleaser:
  goreleaser --snapshot --clean

test:
  tuiftp.exe config